<template>
  <div>
    <el-table :data="list" style="width: 100%">
      <el-table-column prop="realname" label="员工姓名" width="" />
      <el-table-column prop="mobile" label="手机号" width="" />

      <el-table-column prop="position" label="职位" width="" />
      <el-table-column prop="tenant_name" label="账号" width="" />
      <el-table-column label="操作">
        <template slot-scope="scope">
          <span class="edit" @click="edit(scope)">编辑</span>
          <span class="delete" @click="handleDelete(scope)">删除</span>
        </template>
      </el-table-column>
    </el-table>
  </div>
</template>
<script>
export default {
  props: {
    list: {
      type: Array,
      default: () => {}
    }
  },
  data() {
    return {
    }
  },
  methods: {
    edit(scope) {
      this.$emit('editAuth', scope.row.id)
    },
    handleDelete(scope) {
      this.$emit('deleteAdmin', scope.row.id)
    }
  }
}
</script>
<style lang="scss" scoped>
@import "@/styles/el-table.scss";
.el-table /deep/ .cell {
  .edit {
    color: #409eff;
    margin-right: 24px;
    cursor: pointer;
    white-space: nowrap;
  }
  .delete {
    color: #f56c6c;
    cursor: pointer;
    white-space: nowrap;
  }
}

</style>
